<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
<head>
    <th:block th:include="include :: header('会员收费标准管理')"/>
</head>
<body class="gray-bg">
<div class="container mt-4">
    <a th:href="@{/price/grDetail/toSave/{id}(id=${categoryId})}" class="btn btn-success mb-3">新增细项</a>
    <table class="table table-striped table-bordered">
        <thead class="thead-dark">
            <tr>
                <th>ID</th>
                <th>名称</th>
                <th>价格</th>
                <th>单位</th>
            </tr>
        </thead>
        <tbody>
            <tr th:each="card : ${grDetails}">
                <td th:text="${card.id}"></td>
                <td th:text="${card.vtName}"></td>
                <td th:text="${card.vtPrice}"></td>
                <td th:text="${card.unit}"></td>
                <td>
                    <a th:href="@{/price/grDetail/edit/{id}(id=${card.id})}" class="btn btn-sm btn-primary">编辑</a>
                    <a th:href="@{/price/grDetail/delete/{id}(id=${card.id})}" class="btn btn-sm btn-primary">删除</a>
                </td>
            </tr>
            <tr th:if="${grDetails.isEmpty()}">
                <td colspan="6" class="text-center">暂无数据</td>
            </tr>
        </tbody>
    </table>
</div>
</body>
</html>